public class SelectSort {
    public static void mySelectSort(int[] array) {
        int minNum = 0;
        int tmp = 0;
        for (int i = 0; i < array.length; i++) {
            minNum = array[i];
            for (int j = i+1; j < array.length-1; j++) {
                if (minNum >= array[j]) {
                    tmp = array[j];
                    array[j] = minNum;
                    minNum = tmp;
                }
            }
            array[i] = minNum;
        }
    }

}
